package hari2.latihan;
import java.io.*;

public class Stream1 {
	public static void main(String[] args) {
		int size;
		
		try {
			InputStream f1 = new FileInputStream("src/hari2/latihan/files.txt");
			size = f1.available();
			System.out.println("available bytes: " + size);
			for (int i = 0; i < size; i++) {
				System.out.println((char) f1.read());
			}
			f1.close();
		} catch (java.io.IOException e) {
			System.out.println(e);
		}
	}
}
